<!doctype html>

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>TrainTicket Admin</title>
    <meta name="description" content="This is the admin page of TrainTicket system">
    <meta name="keywords" content="index">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="renderer" content="webkit">
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <link rel="icon" type="image/png" href="assets/i/favicon.png">
    <link rel="apple-touch-icon-precomposed" href="assets/i/app-icon72x72@2x.png">
    <meta name="apple-mobile-web-app-title" content="Amaze UI" />
    <link rel="stylesheet" type="text/css" href="css/style.css">
    <link rel="stylesheet" type="text/css" href="css/bootstrap.css">
    <link rel="stylesheet" type="text/css" href="css/bootstrap-theme.css">
    <link rel="stylesheet" href="assets/css/amazeui.min.css" />
    <link rel="stylesheet" href="assets/css/admin.css">
    <link rel="stylesheet" href="assets/css/app.css">
    <link rel="stylesheet" href="assets/css/cropper.min.css" />
    <link rel="stylesheet" href="assets/css/client.css">

    <script type="text/javascript" src="assets/js/vue.js"></script>
    <script type="text/javascript" src="assets/js/vue-upload-component.js"></script>
    <script type="text/javascript" src="assets/js/client_common.js" defer charset="utf-8"></script>
    <script type="text/javascript" src="assets/js/jquery.shCircleLoader-min.js" defer charset="utf-8"></script>
    <script type="text/javascript" src="assets/js/jquery.min.js"></script>
    <script type="text/javascript" src="assets/js/amazeui.min.js"></script>
    <script type="text/javascript" src="assets/js/app.js"></script>
    <script type="text/javascript" src="assets/js/cropper.min.js"></script>

    <style>
        .avatar .avatar-upload .rounded-circle {
            width: 200px;
            height: 200px;
        }

        .rounded-circle {
            border-radius: 50%;
        }

        .avatar .text-center .btn {
            margin: 0 .5rem
        }

        .avatar .avatar-edit-image {
            max-width: 100%
        }

        .avatar .drop-active {
            top: 0;
            bottom: 0;
            right: 0;
            left: 0;
            position: fixed;
            z-index: 9999;
            opacity: .6;
            text-align: center;
            background: #000;
        }

        .avatar .drop-active h3 {
            margin: -.5em 0 0;
            position: absolute;
            top: 50%;
            left: 0;
            right: 0;
            -webkit-transform: translateY(-50%);
            -ms-transform: translateY(-50%);
            transform: translateY(-50%);
            font-size: 40px;
            color: #fff;
            padding: 0;
        }

        .edit-img {
            display: block;
            max-width: 100%;
            max-height: 500px;
        }

        .btn-area {
            margin: 5px;
        }
    </style>
</head>

<body data-type="generalComponents">
    <header class="am-topbar am-topbar-inverse admin-header">
        <div class="am-topbar-brand">
            <a href="javascript:;" class="tpl-logo">
                <img src="assets/img/logo.png" alt="">
            </a>
        </div>
        <div class="am-icon-list tpl-header-nav-hover-ico am-fl am-margin-right">

        </div>

        <button class="am-topbar-btn am-topbar-toggle am-btn am-btn-sm am-btn-success am-show-sm-only"
            data-am-collapse="{target: '#topbar-collapse'}"><span class="am-sr-only">导航切换</span> <span
                class="am-icon-bars"></span></button>

        <div class="am-collapse am-topbar-collapse" id="topbar-collapse">

            <ul class="am-nav am-nav-pills am-topbar-nav am-topbar-right admin-header-list tpl-header-list">

                <li id="goto_admin">
                    <a href="adminlogin.html" class="tpl-header-list-link">
                        <span>admin-panel</span>
                    </a>
                </li>

                <li class="am-hide-sm-only"><a href="javascript:;" id="admin-fullscreen"
                        class="tpl-header-list-link"><span class="am-icon-arrows-alt"></span> <span
                            class="admin-fullText">FullScreen</span></a>
                </li>

                <li class="am-dropdown" data-am-dropdown data-am-dropdown-toggle>
                    <a href="upload_avatar.html" tpl-header-list-link">
                        <span class="tpl-header-list-user-nick" id="client_name">Not Login</span>
                        <span class="tpl-header-list-user-ico">
                            <img id="avatar_img">
                        </span>
                    </a>
                </li>

                <li id="logout_button">
                    <a href="#" class="tpl-header-list-link">
                        <span class="am-icon-sign-out tpl-header-list-ico-out-size"></span>
                    </a>
                </li>
            </ul>
        </div>
    </header>

    <div class="tpl-page-container tpl-page-header-fixed">
        <div class="tpl-left-nav tpl-left-nav-hover">
            <div class="tpl-left-nav-title">
                Management
            </div>
            <div class="tpl-left-nav-list">

                <ul class="tpl-left-nav-menu">
                    <li class="tpl-left-nav-item">
                        <a href="index.html" class="nav-link">
                            <i class="am-icon-list-alt"></i>
                            <span>Ticket Reserve</span>
                            <i class="am-icon-star tpl-left-nav-content-ico am-fr am-margin-right"></i>
                        </a>
                    </li>

                    <li class="tpl-left-nav-item">
                        <a href="client_order_list.html" class="nav-link tpl-left-nav-link-list">
                            <i class="am-icon-line-chart"></i>
                            <span>Order List</span>
                        </a>
                    </li>

                    <li class="tpl-left-nav-item">
                        <a href="client_consign_list.html" class="nav-link tpl-left-nav-link-list">
                            <i class="am-icon-globe"></i>
                            <span>Consign List</span>
                        </a>
                    </li>

                    <li class="tpl-left-nav-item">
                        <a href="client_adsearch.html" class="nav-link tpl-left-nav-link-list">
                            <i class="am-icon-users"></i>
                            <span> Advanced Search</span>
                        </a>
                    </li>


                    <li class="tpl-left-nav-item">
                        <!-- 打开状态 a 标签添加 active 即可   -->
                        <a href="javascript:;" class="nav-link tpl-left-nav-link-list">
                            <i class="am-icon-table"></i>
                            <span>Execute Flow</span>
                            <i class="am-icon-angle-right tpl-left-nav-more-ico am-fr am-margin-right"></i>
                        </a>
                        <ul class="tpl-left-nav-sub-menu">
                            <li>
                                <!-- 打开状态 a 标签添加 active 即可   -->
                                <a href="client_ticket_collect.html" class="active">
                                    <i class="am-icon-user"></i>
                                    <span>Ticket Collect</span>
                                </a>

                                <a href="client_enter_station.html">
                                    <i class="am-icon-institution"></i>
                                    <span>Enter Station</span>
                                </a>
                            </li>
                        </ul>
                    </li>

                </ul>

            </div>
        </div>

        <div class="tpl-content-wrapper" id="reserveApp">
            <div class="tpl-portlet-components">
                <div class="portlet-title">
                    <div class="caption font-green bold">
                        Upload Avatar
                    </div>
                </div>

                <div id="app" class="am-g container avatar">
                    <div v-show="$refs.upload && $refs.upload.dropActive" class="drop-active">
                        <h3>Drop files to upload</h3>
                    </div>
                    <div class="avatar-upload" v-show="!edit">
                        <div class="text-center p-2">
                            <label for="avatar">
                                <img :src="files.length ? files[0].url : avatarUrl" class="rounded-circle" />
                                <h4 class="pt-2">or<br />Drop files anywhere to upload</h4>
                            </label>
                        </div>
                        <div class="text-center p-2">
                            <file-upload class="btn btn-primary" extensions="gif,jpg,jpeg,png,webp"
                                accept="image/png,image/gif,image/jpeg,image/webp" :custom-action="upload" :drop="!edit"
                                v-model="files" @input-filter="inputFilter" @input-file="inputFile" ref="upload">
                                Upload Avatar
                            </file-upload>
                        </div>
                    </div>

                    <div class="avatar-edit" v-show="files.length && edit">
                        <div v-if="files.length">
                            <img class="edit-img" ref="editImage" :src="files[0].url" />
                        </div>
                        <div class="btn-area text-center p-4">
                            <button type="button" class="btn btn-secondary"
                                @click.prevent="$refs.upload.clear">Cancel</button>
                            <button type="submit" class="btn btn-primary" @click.prevent="editSave">Save</button>
                        </div>
                    </div>
                </div>

            </div>
        </div>
    </div>

</body>
<script type="text/javascript" src="js/upload.js"></script>

</html>